package com.example.units;

import android.content.Context;
import android.graphics.Typeface;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

public class GlobalParameters {

	public static void overrideFonts(final Context context, final View v) 
	{
	      try 
	      {
		        if (v instanceof TextView ) 
		        {
		          ((TextView) v).setTypeface(Typeface.createFromAsset(context.getAssets(), "neucha.otf"));
		        }
		        
		        if (v instanceof Button ) 
		        {
			        ((Button) v).setTypeface(Typeface.createFromAsset(context.getAssets(), "neucha.otf"));
			    }
	      } 
	      catch (Exception e) 
	      {
	    	  
	      }
	    }
}
